# Contributor: Carlos Giraldo <cgiraldo@gradiant.org>
# Maintainer: Carlos Giraldo <cgiraldo@gradiant.org>
pkgname=py3-scikit-learn
pkgver=0.23.1
pkgrel=1
pkgdesc="a Python module for machine learning built on top of SciPy"
url="https://scikit-learn.org"
arch="all !mips !mips64 !s390x" # limited by py3-numpy and py3-joblib
license="BSD-3-Clause"
options="!check" # no test suite
depends="py3-numpy py3-scipy py3-joblib"
makedepends="cython py3-setuptools py3-numpy-dev python3-dev"
source="https://files.pythonhosted.org/packages/source/s/scikit-learn/scikit-learn-$pkgver.tar.gz"
builddir="$srcdir/scikit-learn-$pkgver"

case "$CARCH" in
	aarch64)
		export SKLEARN_NO_OPENMP=1
		;;
esac

build() {
	python3 setup.py build
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="f4225e2ae0654e5a0eddc566a900bc6e91b2dc498ead473719a3a5bc8c065da10710b43d44fa87ca0d24f699066d2e6c899b6d615b6fb270131265d8fd70982c  scikit-learn-0.23.1.tar.gz"
